package com.fake_Interviews.Mapper;

import com.fake_Interviews.module.Login;
import com.fake_Interviews.module.LoginExample;

import java.util.List;

import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

@Mapper
public interface LoginMapper {
//    //    插入用户
    @Insert("insert into login(username, password, role) value (#{username,jdbcType=VARCHAR}, #{password,jdbcType=VARCHAR}, 0);")
    void adduser(Login login);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table login
     *
     * @mbg.generated Tue Aug 23 21:51:09 CST 2022
     */
    long countByExample(LoginExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table login
     *
     * @mbg.generated Tue Aug 23 21:51:09 CST 2022
     */
    int deleteByExample(LoginExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table login
     *
     * @mbg.generated Tue Aug 23 21:51:09 CST 2022
     */
    int deleteByPrimaryKey(Integer id);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table login
     *
     * @mbg.generated Tue Aug 23 21:51:09 CST 2022
     */
    int insert(Login record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table login
     *
     * @mbg.generated Tue Aug 23 21:51:09 CST 2022
     */
    int insertSelective(Login record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table login
     *
     * @mbg.generated Tue Aug 23 21:51:09 CST 2022
     */
    List<Login> selectByExample(LoginExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table login
     *
     * @mbg.generated Tue Aug 23 21:51:09 CST 2022
     */
    Login selectByPrimaryKey(Integer id);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table login
     *
     * @mbg.generated Tue Aug 23 21:51:09 CST 2022
     */
    int updateByExampleSelective(@Param("record") Login record, @Param("example") LoginExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table login
     *
     * @mbg.generated Tue Aug 23 21:51:09 CST 2022
     */
    int updateByExample(@Param("record") Login record, @Param("example") LoginExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table login
     *
     * @mbg.generated Tue Aug 23 21:51:09 CST 2022
     */
    int updateByPrimaryKeySelective(Login record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table login
     *
     * @mbg.generated Tue Aug 23 21:51:09 CST 2022
     */
    int updateByPrimaryKey(Login record);
}
